#!/bin/bash
HERE=`pwd`
export RUN_LIB=/usr/local/bin/cloonix/server/dpdk/lib

if [ ! -d ../../../../tmpbuild/cloonix/server/dpdk ]; then
  if [ ! -d ../../dpdk/include ]; then
    cd ${HERE}/../../dpdk
    ./dpdk.sh
    cd ${HERE}
  fi
fi

if [ -d ../../dpdk/dpdk ]; then
  export RTE_SDK=${HERE}/../../dpdk/
else 
  if [ -d ../../../../tmpbuild/cloonix/server/dpdk ]; then
    export RTE_SDK=${HERE}/../../../../tmpbuild/cloonix/server/dpdk
  else
    echo PROBLEME
    exit 1
  fi
fi

make

